/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package es.usj.dssie.videoclub.dto;

import java.io.Serializable;
import java.util.Date;

/**
 *
 * @author Nacho
 */
public class PeliculasAlquiladas implements Serializable{

    private int idMovie;
    private int idClient;
    private Date startRent;
    private Date endRent;

    public PeliculasAlquiladas(){}
    public Date getEndRent() {
        return endRent;
    }

    public void setEndRent(Date endRent) {
        this.endRent = endRent;
    }

    public int getIdClient() {
        return idClient;
    }

    public void setIdClient(int idClient) {
        this.idClient = idClient;
    }

    public int getIdMovie() {
        return idMovie;
    }

    public void setIdMovie(int idMovie) {
        this.idMovie = idMovie;
    }

    public Date getStartRent() {
        return startRent;
    }

    public void setStartRent(Date startRent) {
        this.startRent = startRent;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final PeliculasAlquiladas other = (PeliculasAlquiladas) obj;
        if (this.idMovie != other.idMovie) {
            return false;
        }
        if (this.idClient != other.idClient) {
            return false;
        }
        if (this.startRent != other.startRent && (this.startRent == null || !this.startRent.equals(other.startRent))) {
            return false;
        }
        if (this.endRent != other.endRent && (this.endRent == null || !this.endRent.equals(other.endRent))) {
            return false;
        }
        return true;
    }

    @Override
    public int hashCode() {
        int hash = 5;
        hash = 61 * hash + this.idMovie;
        hash = 61 * hash + this.idClient;
        hash = 61 * hash + (this.startRent != null ? this.startRent.hashCode() : 0);
        hash = 61 * hash + (this.endRent != null ? this.endRent.hashCode() : 0);
        return hash;
    }


}
